<script src="../media/system/js/mootools-core.js" type="text/javascript"></script>
<script src="../media/system/js/core.js" type="text/javascript"></script>
<form action="index.php?top=page&option=com_frcenter" method="post" name="adminForm" id="adminForm">
<!-- LEFT -->
 <?php echo $this->loadTemplate('search','default') ?>
 <!-- END LEFT -->
 
 <!-- CONTENT -->
 <div id="jm-content">
    <div class="cc title">
        <div class="id"><?php echo $this->info_ocba->OCBA_CODE; ?></div>
        <div class="cc-title">
            <p class="top"><?php echo $this->info_ocba->OCBA_KANA; ?></p>
            <p class="bot"><?php echo $this->info_ocba->OCBA_NAME; ?><span class="float-right">【<?php echo $this->info_ocba->OCBA_SHOR; ?>】</span></p>
        </div>
    </div>
    <div class="clearfix"></div>
    <div class="menu-cc">
        <ul id="nav">
        
        <?php 
            foreach(bgData::getMenuDetailCenter() as $key=>$item){
                $acctive = 'normal';
                if(JRequest::getVar('task') == $key){
                    $acctive = 'current';
                }
         ?>
            <li class="<?php echo $acctive; ?>"><a href="index.php?top=page&option=com_frcenter&task=<?php echo $key; ?>&id=<?php echo $this->info_ocba->OCBA_CODE; ?>"><?php echo $item; ?></a></li>
          <?php } ?>
            
        </ul>
    </div>
    
    <div id="">
     <h3 class="h_title">プール<span class="right">更新日:<?php if($this->row->POOL_DATE!='0000-00-00 00:00:00' && $this->row->POOL_DATE!=null) echo HelperBG::F_GetDate_JP($this->row->POOL_DATE); ?></span></h3>     
        <div class="info-basic">                            
            <div>
            <?php
                /*if($this->row->POOL_CODE != null  && !empty($this->row->POOL_ADMN)){*/
                    
                    if($this->row->POOL_CODE != null){
          
            ?>
                    <table width="100%" border="0" cellspacing="0" cellpadding="0" >
                        <tbody>
                            <tr>                                        
                                <td style="width: 3%;"><label class="title_">基本データ</label></td>
                                <td style="width: 18%;" >【開設日】</td>                               
                                <td style="width: 65%;"><?php if($this->row->POOL_SDATE!='0000-00-00 00:00:00' && $this->row->POOL_SDATE!=null) echo HelperBG::F_GetDate_JP($this->row->POOL_SDATE); ?></td>
                            </tr>
                            <tr>
                                 <td><label class="title_"></label></td>
                                <td >【譲渡日】</td>
                                <td><?php if($this->row->POOL_TDATE!='0000-00-00 00:00:00' && $this->row->POOL_TDATE!=null) echo HelperBG::F_GetDate_JP($this->row->POOL_TDATE); ?></td>
                            </tr>
                            <tr>
                                <td><label class="title_"></label></td>
                                <td >【運営委託業者】</td>
                                <td colspan="2"><?php echo $this->row->POOL_ADMN; ?></td>
                            </tr>
                            <tr>
                                 <td><label class="title_"></label></td>
                                <td >【開館期間】</td>
                                <td  colspan="2"><?php echo $this->row->POOL_TERM; ?></td>
                            </tr>
                            <tr>
                                 <td><label class="title_"></label></td>
                                <td >【プール種別】</td>
                                <td  colspan="2"><?php echo $this->row->POOL_POLK; ?></td>
                            </tr>
                            <tr>
                                 <td><label class="title_"></label></td>
                                <td >【温水種別】</td>
                                <td colspan="2"><?php echo $this->row->POOL_POHK; ?></td>
                           </tr>
                            <tr>
                                
                                <td colspan="4"><hr /></td>
                            </tr>
                        </tbody>
                    </table>
                    <table width="100%" cellpadding="0" cellspacing="0" border=0>
                        <tbody>
                            <tr>
                                <td style="width: 3%;"><label class="title_">設備</label></td>
                                <td style="width: 20%;">【拡張施設】</td>                               
                            <?php
                            $ar=$this->row->extend;
                                $i=0;
                                $count_all=count($this->list_tbpo);
                                foreach ($this->list_tbpo as $k=>$value)
                                {
                                    $str='□';
                                    $i++;
                                    $count_all--;
                             ?>
                            <td style="width:24%;">
                                        <?php foreach ($ar as $k=>$vl)
                                    {
                                        if ($value->TBPO_CODE==$vl)
                                        {
                                            $str='■';
                                        }
                                    }
                                        ?>
                            
                                 <?php echo $str.$value->TBPO_NAME; $str='□' ?>
                                <?php
                                    if ($i == 3 && $count_all > 0)
                                    {
                                        $i=0;
                                        echo "</td></tr><tr><td></td><td>";
                                    } 
                                ?>
                            </td>  
                            <?php } ?>  
                                    
                          
                            </tr>
                            <tr>
                                <td></td>
                                <td colspan="5"><hr /></td>
                            </tr>
                            <tr>
                                <td><label class="title_"></label></td>
                                <td >【バリアフリー】</td>   
                            <?php
                            $ar=$this->row->disabled;
                                $i=0;
                                $j=count($this->list_disp);
                                foreach ($this->list_disp as $k=>$value)
                                {
                                    $str='□';
                                    $i++;
                                    $j--;
                             ?>
                            <td>
                                        <?php foreach ($ar as $k=>$vl)
                                    {
                                        if ($value->DISP_CODE==$vl)
                                        {
                                            $str='■';
                                        }
                                    }
                                        ?>
                            
                                 <?php echo $str.$value->DISP_NAME; $str='□' ?>
                                <?php
                                    if ($i==3 && $j >0)
                                    {
                                        $i=0;
                                        echo "</td></tr><tr><td></td><td>";
                                    } 
                                ?>
                            </td>  
                            <?php } ?>  
                                    
                            <tr>
                                <td></td>
                                <td colspan="5"><hr /></td>
                            </tr>
                             <tr style="vertical-align:top">
                                <td><label class="title_"></label></td>
                                <td>【施設利用】</td>
                                <td class="tb_5c">なし</td>
                                <td colspan="3" class="tb_2c">※プールに設置されたミーティングルームの利用法</td>
                              
                            </tr>
                            <tr><td colspan="6"><hr /></td></tr>
                        </tbody>
                    </table>
                    
                    <table width='100%' cellpadding="0" cellspacing="0" border=0>
                        <tbody>
                           <tr>
                                <td><label class="title_">その他</label></td>
                                <td  style="width:20%;">【料金】</td>
                                <td style="width: 20%;">町内大人：<?php if($this->row->POOL_CIAD != null){ echo $this->row->POOL_CIAD."円"; } ?> </td>

                                <td style="width: 60%;">町内子供：<?php if($this->row->POOL_CICI != null){ echo $this->row->POOL_CICI."円"; } ?> </td>
 
                            </tr>
                            <tr>
                                <td><label class="title_"></label></td>
                                <td class=""></td>
                                <td class="">町外大人：<?php if($this->row->POOL_COAD != null){ echo $this->row->POOL_COAD."円"; } ?></td>
                         
                                <td class="">町外子供：<?php if($this->row->POOL_COCI != null){ echo $this->row->POOL_COCI."円"; } ?></td>
                   
                            </tr>
                            
                            <tr>
                                <td><label class="title_"></label></td>
                                <td class=""></td>
                                <td class="">備考：</td>
                                <td class="" colspan="3"><?php echo $this->row->POOL_CNOT; ?></td>
                            </tr>
                            <tr><td></td><td colspan="6"><hr /></td></tr>
                            <tr>
                                <td><label class="title_"></label></td>
                                <td class="">【備考】</td>
                                <td colspan="4"><?php echo HelperBGtop::newline2br($this->row->POOL_NOTE); ?></td>
                                
                            </tr>
                            <tr><td colspan="6"><hr /></td></tr>
                        </tbody>
                    </table>
         <?php
             }else{
                echo '<p align="center" >データは見つかりませんでした</p>';
             }
         ?>          
                    
         </div>
        </div>  
        <input type="hidden" name="task" value=""/>
        <input type="hidden" name="boxchecked" value="0"/>                             
        
</div>
    
 </div>
 <!-- END CONTENT -->
                           
</form>
